import axios from './request'
// 展示分页的商品分类
export const getCateApi = (data) => axios.get('cate',{params: data})
// 不分页的商品分类
export const getCateApiNowPagenation =  axios.get('cate')

// 添加分类
export const addCateApi = (data) => axios.post('cate', data)

// 删除分类
export const delCateApi = (id) => axios.delete('cates/'+id)

// 获取单条数据
export const getCateOneApi = (id) => axios.get('cates/'+id)

// 修改分类
export const editCateApi = ({id, data}) => axios.patch('cates/'+id, data)